/*
 * 视频列表搜索
 * @Author: ljb 
 * @Date: 2017-11-27 15:24:29 
 * @Last Modified by: ljb
 * @Last Modified time: 2018-01-30 10:38:52
 */
<template>
<Form ref="formInline" inline :label-width="100">

    <Form-item label="视频分类" porp="video_type_id">
        <Select v-model="formValidate.video_type_id" clearable  filterable>
            <Option v-for="( value , key ) in videoTypes" :value="key + ''" :key="key">{{ value }}</Option>
        </Select>
    </Form-item>
    
    <Form-item label="视频名称" prop="title">
         <Input v-model="formValidate.name" type="text" placeholder="请输入视频名称"></Input>
    </Form-item> 

    <Form-item>
        <Button type="primary" @click="confirmSearch">搜索</Button>
    </Form-item>
    
</Form>
</template>
<script>

export default {

    name: 'product-search-form',

    props: ['videoTypes'],

    data: function () {
        return {

            // real_date : '',             //格式化的时间

            formValidate : {
                 
                video_type_id: '',

                name : ''

            },                  //搜索框的对象参数
        }
    },

    mounted() {

    },

    methods: {

        /**
         * 确认搜索
         * @return {undefined}
         */
        confirmSearch(){

            const param = {

                video_type_id : this.formValidate.video_type_id,

                name: this.formValidate.name

            }

            this.$emit('search',param);

        }
        
    },
    
}

</script>